<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>计算圆的面积和周长</title>
</head>
<body>
    <script>
        function Area(r){
            r = r || 0; 
            var pai = 3.1415926
            return pai*r*r;
        }
        var area = Area(5);
        document.write('半径为5的圆的面积是:'+area);
        //求圆的周长
        function Long(r){
        r= r || 0;
        var pai = 3.1415926;
        return 2*pai*r;
        }
        var long = Long(5);
        document.write('半径为5的圆的周长是:' +long);
    </script>
</body>
</html